<template>
	<view class=" team">
		<div class="Site" style="overflow: visible;">
			 
			<div class="Site PageBox">
				<div class="van-nav-bar van-nav-bar--fixed">
					<div class="van-nav-bar__content">
						<div class="van-nav-bar__left" @click="back">
							<u-icon name="arrow-left" color="#fff" size="32rpx"></u-icon>
						</div>
						<div class="van-nav-bar__title van-ellipsis" style="color: #fff;margin-left: 56rpx;">{{common.teamReport.default[0]}}</div>
					<!-- 	<div class="van-nav-bar__right">
							<div><button
									class="van-button van-button--default van-button--min"
									  @click="dumprun('/pages/setting/share')" 
									style="width: 100px; height: 26px; color: rgb(255, 255, 255); background: #0076fa; border-color: #0076fa;">
									<div class="van-button__content"><span
											class="van-button__text"><span>{{common.common7[5]}}</span></span></div>
								</button></div>
						</div> -->
					</div>
				</div>
				<!-- <div style="display: flex;"> -->
					<!-- <div class="Menu2item1">
						<div style="color: rgb(204, 204, 204);">{{common.common7[6]}} </div>
						<div style="color: rgb(231, 231, 231);"> {{list.subordinate_num}} </div>
					</div> -->
				<!-- 	<div class="Menu2item1">
						<div style="color: rgb(204, 204, 204);">{{common.common7[7]}} </div>
						<div style="color: rgb(231, 231, 231);"> {{list.subordinate_num}} </div>
					</div> -->
				<!-- </div> -->
				<view class="newlist">
					<view class="new-item">
						<view class="new-name">{{common.teamReport.default[1]}}</view>
						<view class="new-tils">
							{{teamData.subordinate_num}}
						</view>
						
					</view>
					<!-- <view class="new-item" v-for="item in teamData.list" :key="item.id">
						<view class="new-name">{{item.id}} </view>
						<view class="new-tils" style="font-size: 32rpx;">
							{{item.username}}
						</view>
						
					</view> -->
				</view>
				<view class="ask-btn">
					邀请好友
				</view>
				<!-- <view class="team_card">
					<text>{{common.teamReport.default[1]}}</text>
					<text>{{teamData.subordinate_num}}</text>
				</view> -->
				
				<!-- <view class="team_list">
					<view class="team_list_item"   
					v-for="item in teamData.list" :key="item.id">
						{{item.id}} - {{item.username}}
					</view>
					
					<empty :promptText="common.empty[0]" :showEmpty="teamData.list && teamData.list.length == 0" />
				</view> -->
			</div>
		</div>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				isshow: false,
				teamData:[]
			};
		},
		onLoad(options) {
			const {
				id
			} = options
			this.id = id
			this.getlist()
		},
		onShow() {
	
		},
		methods: {
			getlist(){
				const token = uni.getStorageSync('token')
				this.$u.api.index.team_list(token).then(res => {
					this.teamData = res.data
				})
			},
			back() {
				const pages = getCurrentPages();
				if (pages.length === 2) {
					uni.navigateBack({
						delta: 1
					});
				} else if (pages.length === 1) {
					uni.switchTab({
						url: '/pages/index/index',
					})
				} else {
					uni.navigateBack({
						delta: 1
					});
				}
			},
			dumprun(url) {
				uni.navigateTo({
					url
				})
			},
		},
		computed: {
			common() {
				return this.$t("common")
			},
		}
	}
</script>

<style scoped lang="scss">
	.Site .van-nav-bar .van-icon {
	    font-size: 1.5rem !important;
	    color: #bbb !important;
	}
	.PageBox {
		color: #635327;
	    padding-top: 40px;
		background-color: #2A2D34;
		overflow-y: scroll;
	}

	.van-nav-bar {
		background-color: #2A2D34;
	}

	.van-nav-bar .van-nav-bar__title {
		color: #222;
		font-weight: 700
	}

	.Menu2item1 {
		margin-top: 10px;
		background-color: #191c23;
		line-height: 25px;
		margin-left: 10px;
		width: 48%;
		text-align: center;
		padding: 10px
	}

	.ScrollBox {
		background-color: #2A2D34;
	}
	
	.team{
		padding:0 22rpx;
		background-color: #2A2D34;
		.van-nav-bar{
			background-color: #1a1a1a;
		}
		.team_card{
			padding: 20rpx 0;
			display: flex;
			flex-direction: column;
			align-items: center;
			justify-content: space-around;
			height: 180rpx;
			border-radius: 12rpx;
			background: url('../../static/image/news/team_card.png') 100% / 100% no-repeat;
			& > text:nth-child(2){
				font-size: 38rpx;
				font-weight: 700;
			}
		}
		
		.team_list{
			min-height: 800rpx;
			.team_list_item {
				
				margin-top: 20rpx;
				padding: 30rpx;
				color: #222;
				background-color: #fff;
				border-radius: 10rpx;
			}
		}
	}
	.newlist{
		
		box-sizing: border-box;
		.new-item{
			margin-top: 16rpx;
			width: 708rpx;
			height: 162rpx;
			background-image: url('../../static/image/my/txbj.png');
			background-size: 100% 100%;
			padding-top: 36rpx;
			padding-left: 40rpx;
			.new-name{
				font-family: Inter, Inter;
				font-weight: 400;
				font-size: 22rpx;
				color: #000000;
			}
			.new-tils{
				margin-top: 20rpx;
				font-family: WeChat Sans Std, WeChat Sans Std;
				font-weight: 500;
				font-size: 40rpx;
				color: #000000;
			}
		}
	}
	.ask-btn{
		margin-top: 54rpx;
		width: 708rpx;
		height: 88rpx;
		background: #03E4DF;
		border-radius: 8rpx 8rpx 8rpx 8rpx;
		font-family: PingFang SC, PingFang SC;
		font-weight: bold;
		font-size: 32rpx;
		color: #111111;
		text-align: center;
		line-height: 88rpx;
	}
</style>